﻿var hh5= "#fEffect/ItemEff/3012023/1/9#";//拟人化星星
var hh7= "#fEffect/ItemEff/3994441/8#";//小精灵
var status = -1;

function action(mode, type, selection) {
    if (mode == 1) {
        status++;
    } else {
        if (status == 0) {
            cm.sendOk("#e真的要放弃这次获取以下物品的机会了么?"+hh7+"\r\n#v2430209#* 1#v5062009#*100#v5062500#*100#v5062024#*40#v2614002#*5\r\n#v1712001##v1712002##v1712003##r神秘徽章一套#k\r\n#v2435087##b玛瑙材料礼包II#k#v2434174##b玛瑙材料礼包#k#r#v2436382#战力礼包IV#k\r\n");
            cm.dispose();
        }
        status--;
    }
    if (status == 0) {
        cm.sendYesNo("#e#b#v2436379#战力礼包III#k  (价值约1050余额)\r\n"+"打开该礼包,将获取#v2430209#* 1个,以及各类强大的道具祝您起飞!\r\n#v5062009#*100#v5062500#*100#v5062024#*40#v2614002#*5#v1712001##v1712002##v1712003##r神秘徽章一套#k\r\n#v2435087##b玛瑙材料礼包II#k#v2434174##b玛瑙材料礼包#k#r#v2436382#战力礼包IV#k\r\n#r警告#k:一定要保持背包每栏至少留有#g10#k个空位哟,否则东西少了我是不负责的哟~\r\n\r\n是否花费#r666#k余额打开该礼包？#k");
    } else if (status == 1) {
        if (cm.getHyPay(1)> 666){
 	cm.sendOk("恭喜你成功打开了战力礼包I,快去背包里查看把!");
        cm.addHyPay(666);
        cm.gainItem(2436379, -1);
        cm.gainItem(2430209, 1);
        cm.gainItem(1712001, 1);
        cm.gainItem(1712002, 1);
        cm.gainItem(1712003, 1);
        cm.gainItem(2614002, 5);
        cm.gainItem(5062009, 100);
        cm.gainItem(5062500, 100);
        cm.gainItem(5062024, 40);
        cm.gainItem(2435087, 1);
        cm.gainItem(2434174, 1);
        cm.gainItem(2436382, 1);
        cm.dispose();
}
      else{             
       cm.sendOk(hh5+"\r\n#e您的#r余额#k不足哟~~是否考虑消费一下下来起飞呢?");
       cm.dispose();
          }
    }
}